package com.baidu.day02;

public class Demo06 {
    public static void main(String[] args) {
        String str = "hello,world";

        //str.length() 返回字符串的长度
        System.out.println(str.length());// 11

        //str.contains() 判断字符串中是否包含某个子串
        System.out.println(str.contains("h"));// true

        String str1 = "a";
        String str2 = "b";
        String str3 = str1 + str2;
        String str4 = "ab";
        System.out.println(str3.equals(str4));// true
    }
}
